# ---------- ---------- ---------- ---------- ---------- ----------
#
#   fenrispunk
#
# ---------- ---------- ---------- ---------- ---------- ----------

target: help

.PHONY: help
help:
	@echo "Usage: make [PHONY]"
	@sed -n -e '/sed/! s/\.PHONY: //p' Makefile


.PHONY: init
init:
	@git clone https://notabug.org/vaeringjar/fenrispunk-assets.git lib/fenrispunk-assets \
            && rsync -av --delete lib/fenrispunk-assets/artwork/rob_michaud/ \
               site/static/artwork/rob_michaud/ \
            || echo "failed to get fenrispunk-assets"
	@touch headlines.org


.PHONY: build-home
build-home:
	@./build-home-page || echo "Suggestion: make init"


.PHONY: build
build: build-home


.PHONY: rebuild
rebuild: clean build


.PHONY: clean
clean:
	@echo "stub"


.PHONY: flag-terms
flag-terms:
	@echo "Flag terms to avoid:"

	@grep -Iirn 'dungeons \(&\|and\) dragons\|d&d\|\bsins\b\|starfinder' \
            ./ \
            --exclude=Makefile \
            --exclude-dir=archive \
            --exclude-dir=.git \
            --color=always \
            || echo "pass"
